A wide variety of software tools have been developed to facilitate the process of manipulating digital data. For example, digital image editing software applications such as Adobe® Photoshop® (Adobe Systems Incorporated, San Jose, Calif.) allow users to adjust, modify, and otherwise manipulate digital images. Such applications generally allow a user to make global manipulations to an entire image as well as localized manipulations that affect only a selected portion of an image. Localized manipulations are useful, for example, if a user wishes to adjust the brightness of a person's face or change the color hue of a flower without altering the remainder of the image. Localized manipulations also enable a user to copy and/or extract a selected portion of an image. In general, making a localized manipulation can be understood as comprising a two-step process of first selecting a portion of the image that is to be manipulated and then applying the desired manipulation to that selection. Selecting the portion of the image that is to be manipulated generally involves detecting a boundary or “edge” that separates the selected region of the image from the unselected region. In some cases the edge can be defined based entirely on user input, for example by a user drawing a boundary using a mouse or other pointing device. But more often the edge detection process is partially or fully automated using digital image processing techniques. Automating the edge detection process can improve its efficiency and accuracy, which in turn facilitates the creation of a selection mask that more precisely defines the localized portion of the image which is to be copied, extracted, or otherwise manipulated. Once the selection mask is defined, the desired operation can be applied on a localized basis.